import request from '@/utils/request'


export function getStockInfoList(query) {
    return request({
        url: '/stock/queryStockInfoByPage.action',
        method: 'get',
        params: query
    })
}


export function getStockDividendList(query) {
    return request({
        url: '/stock/queryStockDividendByPage.action',
        method: 'get',
        params: query
    })
}


// 查询股票行情列表
export function getStockPriceList(query) {
    return request({
        url: '/stock/queryStockPriceByPage.action',
        method: 'get',
        params: query
    })
}
// 查询股票行情曲线
export function getStockPriceCurve(query) {
    return request({
        url: '/stock/queryStockPriceCurve.action',
        method: 'get',
        params: query
    })
}


// 新增股票信息
export function addStockInfo(data) {
    return request({
        url: '/stock/insertStockInfo.action',
        method: 'post',
        data: data
    })
}

// 修改股票信息
export function updateStockInfo(data) {
    return request({
        url: '/stock/updateStockInfo.action',
        method: 'put',
        data: data
    })
}

// 删除股票信息
export function delStockInfo(data) {
    return request({
        url: '/stock/deleteStockInfo.action',
        method: 'delete',
        data: data
    })
}



// 新增股票分红
export function addStockDividend(data) {
    return request({
        url: '/stock/insertStockDividend.action',
        method: 'post',
        data: data
    })
}

// 修改股票分红
export function updateStockDividend(data) {
    return request({
        url: '/stock/updateStockDividend.action',
        method: 'put',
        data: data
    })
}

// 删除股票分红
export function delStockDividend(data) {
    return request({
        url: '/stock/deleteStockDividend.action',
        method: 'delete',
        data: data
    })
}


// 新增股票行情
export function addStockPrice(data) {
    return request({
        url: '/stock/insertStockPrice.action',
        method: 'post',
        data: data
    })
}

// 修改股票行情
export function updateStockPrice(data) {
    return request({
        url: '/stock/updateStockPrice.action',
        method: 'put',
        data: data
    })
}

// 删除股票行情
export function delStockPrice(data) {
    return request({
        url: '/stock/deleteStockPrice.action',
        method: 'delete',
        data: data
    })
}


